<template>
  <div class="marketTab">
    <div class="marketTabItem" v-if="marketCode === 'ag'" :class="{active:marketCode === 'ag'}"
         >企业动态
    </div>
    <div class="marketTabItem" v-if="marketCode === 'hg'" :class="{active:marketCode === 'hg'}"
         >企业动态
    </div>
  </div>
</template>

<script lang="ts" setup>
const emit = defineEmits(['changeTab']);
interface Props {
  marketCode?: string;
}
const {
  marketCode
} = defineProps<Props>();
// const changeTab = (type: string) => {
//   if (marketCode.value !== type) {
//     marketCode.value = type
//     emit('changeTab', marketCode.value)
//   }
// }
</script>

<style scoped lang="scss">
.marketTab {
  border-radius: 4px;
  // border-bottom: 1px solid #70cdf6;
  padding: 16px 20px 12px 20px;

  .marketTabItem {
    // width: 60px;
    display: inline-flex;
    align-items: center;
    color: #111;
    font-size: 16px;
    width: auto;
    // height: 100%;
    justify-content: center;
    // background: #f2f2f2;
    cursor: pointer;
    font-weight: 600;

    // &.active {
    //   background: #02a7f0;
    //   color: #fff;
    // }
  }
}
</style>
